package com.ruoyi.dynamic.service;


import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.common.core.pojo.result.Pages;
import com.ruoyi.dynamic.model.pojo.entity.Gift;
import com.ruoyi.dynamic.model.pojo.request.app.AppGiftSearchRequest;
import com.ruoyi.dynamic.model.pojo.request.crm.CrmGiftAddOrEditRequest;

import java.util.List;
import java.util.Set;

/**
 * <p>
 * 礼物表 服务类
 * </p>
 *
 * @author ${author}
 * @since 2024-11-27
 */
public interface IGiftService extends IService<Gift> {

    /**
     * 礼物分页查询
     * @param request
     * @param userId
     * @return
     */
    Pages<Gift> listPage(AppGiftSearchRequest request, Long userId);

    /**
     * 校验
     * @param id
     * @return
     */
    Gift verify(Long id);

    /**
     * 添加编辑礼物
     */
    boolean addOrEdit(CrmGiftAddOrEditRequest request);


    /**
     * 换一换礼物
     * @param number
     * @param giftIds
     */
    List<Gift> cutGift(Integer number, Set<Long> giftIds);


}
